<?php
require_once VT_PLUGIN_DIR .'/inc/codestar/codestar-framework.php';

// Control core classes for avoid errors
if( class_exists( 'CSF' ) ) {

    $prefix = VT_PLUGIN_CONFIG;

    CSF::createOptions( $prefix, array(
        'framework_title' => __('LightV 插件设置','vt'),
        'menu_title' => __('LightV 设置','vt'),
        'menu_slug'  => VT_PLUGIN_CONFIG,
        'menu_type' => 'submenu',
        'menu_parent' => 'plugins.php',
        // 'footer_text' => '<img src="https://vtheme.cn/wp-content/themes/fishv/assets/images/logo.png"/>vtheme.cn',
        'footer_text' => 'vtheme.cn',
        'theme' => 'light',
        // 'show_bar_menu' => false,
        // 'show_sub_menu' => false
    ));


    /**
     * 常规设置
     */
    CSF::createSection( $prefix, array(
        'title'  => __('常规设置','vt'),
        'icon'   => 'dashicons dashicons-admin-generic',
        'fields' => array(
            array(
                'id'    => 'wx_app_id',
                'type'  => 'text',
                'title' => __('wx_app_id','vt'),
                'default' => 'wx7da9fdadcc2c433c'
            ),
            array(
                'id'    => 'wx_app_secret',
                'type'  => 'text',
                'title' => __('wx_app_secret','vt'),
                'default' => '6aa2ab38f543b92cf9bcfcb16815b806'
            ),
            array(
                'id'         => 'update_is_on',
                'type'       => 'radio',
                'title'      => __('更新提示','vt'),
                'options'    => array('1' => __('开启','vt'), '0' => __('关闭','vt')),
                'default'    => '0',
                'inline' => true
            ),
            array(
                'id'    => 'app_lastest_ids',
                'type'  => 'text',
                'title' => __('app_lastest_ids','vt'),
                'default' => '10'
            ),
            array(
                'id'    => 'app_hot_ids',
                'type'  => 'text',
                'title' => __('app_hot_ids','vt'),
                'default' => '10'
            ),
            array(
                'id'    => 'app_about_id',
                'type'  => 'text',
                'title' => __('app_about_id','vt'),
                'default' => '7'
            ),
            array(
                'id'    => 'app_using_id',
                'type'  => 'text',
                'title' => __('app_using_id','vt'),
                'default' => '3'
            ),
            array(
                'id'    => 'app_privacy_id',
                'type'  => 'text',
                'title' => __('app_privacy_id','vt'),
                'default' => '377'
            ),
            

        )
    ));


    /**
     * 备份
     */
    CSF::createSection( $prefix, array(
        'title'  => __('备份','vt'),
        'icon'   => 'dashicons dashicons-shield',
        'fields' => array(
            array(
                'type' => 'backup',
            )
        )
    ));


}



